<template>
    <div class="contract">
        <Tabs :value="active" @on-click="changeRoute" :animated="false">
            <TabPane label="已签订合同" name="signed" >
                <router-view></router-view>
            </TabPane>
            <TabPane label="未签订合同" name="not-signed">
               <router-view></router-view>
            </TabPane>
            <TabPane label="合同签订记录" name="record">
               <router-view></router-view>
            </TabPane>
            <TabPane label="合同概况" name="survey">
               <router-view></router-view>
            </TabPane>
        </Tabs>
    </div>   
</template>
<script>
export default {
    data(){
        return {
            active:"signed"
        }
    },
    components:{

    },
    methods: {
        changeRoute(e){
            this.active=e;
            if(e == "signed"){
                this.$router.push("/personnel/relation/contract/signed");
            } else if(e == "anniversary"){
                this.$router.push("/personnel/relation/contract/not-signed");
            }else if(e == "anniversary"){
                 this.$router.push("/personnel/relation/contract/record");
            }else{
                this.$router.push("/personnel/relation/contract/survey");
            }
        }
    },
}
</script>
<style lang="scss" scoped src="./index.scss">
    
</style>